package com.example.java.designpattern;



/**
 * {@link java.io.InputStream}
 * {@link java.io.ByteArrayInputStream}
 * {@link java.io.OutputStream}
 * @author zengty
 * @apiNote 装饰器模式
 * @date 2024/8/29
 * @project study
 */
public abstract class DecorateDivisor implements Divisor {

    private final Divisor divisor;

    protected DecorateDivisor(Divisor divisor){
        this.divisor = divisor;
    }

    @Override
    public void divide(String s) {
        divisor.divide(s);
    }
}
